<!DOCTYPE html>
<?php
	write_session('rURL',uri_string());
?>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="robots" content="follow, index">

<title><?= $template['title'];?> </title>
<?= $template['metadata'];?>
<?= setting('google_analytics');?>

<!-- Twitter -->
<meta name="twitter:card" content="summary">
<meta name="twitter:site"
	content="@<?php echo setting('web_title');?>">
<meta name="twitter:creator" content="<?php echo setting('web_title');?>">
<meta name="twitter:title" content="<?php echo setting('meta_title');?>">
<meta name="twitter:description"
	content="<?php echo setting('meta_description');?>">
<meta name="twitter:image" content="">
<!-- Facebook Open Graph -->
<meta property="og:title" content="<?php echo setting('web_title');?>" />
<meta property="og:type" content="website" />
<meta property="og:description" content="<?php echo setting('meta_description');?>" />
<meta property="og:image" content="" />
<meta property="og:url" content="<?php echo current_url();?>" />
<meta property="og:site_name" content="<?php echo setting('web_title');?>" />
<!-- Google Plus -->
<meta itemprop="name" content="<?php echo setting('web_title');?>" />
<meta itemprop="image" content="" />
<meta itemprop="description" content="<?php echo setting('meta_description');?>" />

<!-- Styles -->

<?php
// add logic if user is logged in to flush the assets cache
// Assets::clear_cache();
?>

<?php Assets::css($this->config->item('theme_css')); ?>
<link
	href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css"
	rel="stylesheet">
<link href="<?= base_url();?>assets/css/style.css" rel="stylesheet">
<link href="<?= base_url();?>assets/css/ypstyle.css" rel="stylesheet">
<link href="<?= base_url();?>assets/css/jquery-ui.css" rel="stylesheet">
<!-- Le HTML5 shim, for IE6-8 support of HTML5 elements -->
<!--[if lt IE 9]>
          <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
        <![endif]-->
<!-- JS -->
<?php Assets::cdn($this->config->item('theme_jscdn')); ?>
<?php  Assets::js($this->config->item('theme_js')); ?>

<script src="<?= base_url();?>assets/js/jquery-ui-1.10.3.custom.js"></script>


<!-- favicon -->
<link rel="shortcut icon"
	href="<?php echo base_url('assets/img/ico/favicon.ico'); ?>">
</head>

<body data-baseurl="<?= base_url(); ?>">

	<section class="header">
		<?php
		if (isset($template['partials']['header']))
			echo $template['partials']['header'];
		?>
	</section>

<? echo $this->setting('web_title'); die();?>
<div class="wrapper">
	<section class="presentation">
		<div class="row">

			<div class="container">
				<div class="m-bot-15">

					<div class="clearfix">
						<div class="w25 block-0 pull-left">

							<div class="block-text">
								WE PROVIDE<br> AWESOME DIGITAL<br> <strong
									class="text-info strong">PRESENCE</strong>

							</div>


						</div>

						<div class="w25 block-1 pull-left">


							<div class="ca-icon">
								<i class="fa fa-5x fa-group"></i>
							</div>
							<div class="ca-content">
								<h2 class="ca-main">GET MORE CUSTOMER</h2>
								<h3 class="ca-sub">Sed ut perspiciatis unde omnis iste natus
									error sit.</h3>
							</div>


						</div>

						<div class="w25 block-2 pull-left">

							<div class="ca-icon">
								<i class="fa fa-5x fa-search"></i>
							</div>
							<div class="ca-content">
								<h2 class="ca-main">SEARCH BUSINESS</h2>
								<h3 class="ca-sub">Sed ut perspiciatis unde omnis iste natus
									error sit.</h3>
							</div>
						</div>

						<div class="w25 block-3 pull-left">
							<div class="">

								<div class="ca-icon">
									<i class="fa fa-5x fa-comments"></i>
								</div>
								<div class="ca-content">
									<h2 class="ca-main">FIND US IN</h2>
									<h3 class="ca-sub">



										<span class="fa-stack fa-lg"> <a href="#"> <i
												class="fa fa-circle fa-stack-2x"></i> <i
												class="fa fa-facebook fa-stack-1x fa-inverse"></i>
										</a>
										</span> <span class="fa-stack fa-lg"> <a href="#"> <i
												class="fa fa-circle fa-stack-2x"></i> <i
												class="fa fa-twitter fa-stack-1x fa-inverse"></i>
										</a>
										</span> <span class="fa-stack fa-lg"> <a href="#"><i
												class="fa fa-circle fa-stack-2x"></i> <i
												class="fa fa-google-plus fa-stack-1x fa-inverse"></i> </a>
										</span> <span class="fa-stack fa-lg"> <a href="#"><i
												class="fa fa-circle fa-stack-2x"></i> <i
												class="fa fa-linkedin fa-stack-1x fa-inverse"></i> </a>
										</span>
									</h3>
								</div>

							</div>
						</div>
					</div>
				</div>
			</div>

		</div>
	</section>

	<div class="row">
		<div class="container">

			<div class="col-md-8">

				<div class="panel ">
					<div class="panel-heading ">
						BROWSE CATEGORY IN <strong class="text-danger"><?= strtoupper($location); ?>
						</strong> <a class="fa-md pull-right" href="<?= base_url();?>category/all"><i
							class="fa fa-list "></i> View All</a>
					</div>
					<div class="panel-body pin">
						<div class="col3">

							<?php 
							if($category){
								foreach ($category as $category):?>

							<?php 
							$subCategory = $this->category_model->getChild($category->id,5,TRUE);
							//print_r($subCat); die();
							?>

							<div class="item">
								<div id="title" contenteditable="false">
									<h3>
										<strong> <a
											href="<?= base_url().url_title($location)."/".$category->slug;?>"
											title="<?= $category->name; ?> in <?= $location; ?>"><i
												class="fa fa-plus text-invarse"></i>&nbsp;<span class="text-danger"><?= $category->name; ?></span>
										</a>
										</strong>

									</h3>
								</div>
								<div class="list">
									<?php 
									if($subCategory){
											foreach ($subCategory as $subCat):?>
									<h4>

																			
										<a href="<?= base_url();?><?= url_title($location); ?>/<?= $subCat->slug; ?>"

											title="<?= $subCat->name; ?> in <?= location(); ?>"> <?= $subCat->name; ?>
										</a>

										

									</h4>
									<?php endforeach;
									}
									?>
									


								</div>
							</div>
							<?php endforeach;
							}
							?>



						</div>
					</div>
				</div>







				<div class="panel">
					<div class="panel-heading">
						BROWSE BY LOCATIONS <a class="fa-md pull-right" href="<?= base_url();?>location/all"><i
							class="fa fa-list "></i> View All</a>
					</div>
					<div class="panel-body pin">

						<div class="col-lg-6">
							<div class="item">
								<div id="title" contenteditable="false">
									<h3>
										<strong>Popular Regions in</strong> <strong
											class="text-danger"><?= ucfirst(config_item('country'));?> </strong>
									</h3>
								</div>

								<?php 
								if($state){
									foreach ($state as $state):?>
								<h4 class="col-md-6">
									<a href="<?= base_url().$state->slug;?>"
										title="Find Business in <?= $state->name; ?>"><?= $state->name; ?>
									</a>
								</h4>
								<?php endforeach;
								}
								?>

							</div>
						</div>

						<div class="col-lg-6">
							<div class="item">
								<div id="title" contenteditable="false">
									<h3>
										<strong>Popular Cities in</strong> <strong class="text-danger"><?= ucfirst(config_item('country'));?>
										</strong>
									</h3>
								</div>
							</div>



							<?php 
							if($city){
									foreach ($city as $city):?>
							<h4 class="col-md-6">
								<a href="<?= base_url().$city->slug;?>"
									title="Find Business in <?= $city->name; ?>"><?= $city->name; ?>
								</a>
							</h4>
							<?php endforeach;
							}
							?>

							<h4 class="col-md-6">
								<!-- <a class="label label-danger" href="<?= base_url();?>city/all" title="View All Cities"><i
									class="fa fa-plus-square-o"></i> All Cities</a> -->
							</h4>
						</div>
					</div>
				</div>
			</div>



			<div class="col-md-4">

				<div class="pin">
					<div class="col2">
						<div class="list">
						<?php foreach($banner as $banner):?>
							<div class="item">

								<img class="img-responsive"
									src="<?=base_url()?>assets/img/advertisement/<?= $banner->value;?>"
									contenteditable="false">

							</div>
							<?php endforeach;?>
<!-- 
							<div class="item">

								<img class="img-responsive"
									src="<?=base_url()?>assets/img/advertisement/bb2.png"
									contenteditable="false">

							</div>
							<div class="item">

								<img class="img-responsive"
									src="<?=base_url()?>assets/img/advertisement/bg2.gif"
									contenteditable="false">

							</div>
							<div class="item">

								<img class="img-responsive"
									src="<?=base_url()?>assets/img/advertisement/bg3.gif"
									contenteditable="false">

							</div>
							<div class="item">

								<img class="img-responsive"
									src="<?=base_url()?>assets/img/advertisement/bg3.gif"
									contenteditable="false">

							</div>
							<div class="item">

								<img class="img-responsive"
									src="<?=base_url()?>assets/img/advertisement/bg3.gif"
									contenteditable="false">

							</div>
							 -->
						</div>
					</div>
				</div>


				<?php
				if (isset($widget_recent_listing) && $widget_recent_listing == TRUE)
					echo Modules::run('widget/recent_listing/show');
				?>


			</div>



		</div>
		<!--/row-->

	</div>

</div>
    <?php
    if (isset($template['partials']['footer']))
        echo $template['partials']['footer'];
    ?>


</body>


</html>
